﻿@model IEnumerable<WebGioiThieu.Models.MenuItem>

    @{
        ViewBag.Title = "ViewMenuItemByMenuType";
    }

    <h2>danh sách menu item</h2>
    <p>
        @Html.ActionLink("Thêm item mới", "Create")
    </p>
    <table>
        <tr>
            <th>Tên
            </th>
            <th>Parent
            </th>
            <td>Thứ tự
            </td>
            <th>Trạng thái
            </th>
            <th></th>
        </tr>
@if (Model != null)
{
        foreach (var item in Model)
        {
            <tr>
                <td>
                    @Html.DisplayFor(model => item.Ten)
                </td>
                <td>
                    @Html.DisplayFor(model => item.Parent)
                </td>
                <td>
                    @Html.DisplayFor(model => item.ThuTu)
                </td>
                <td>
                    @Html.DisplayFor(model => item.TrangThai)
                </td>
                <td>
                    @Html.ActionLink("Edit", "Edit", new { id = item.ID })|
                    @Html.ActionLink("Details", "Details", new { id = item.ID }) |
                    @Html.ActionLink("Delete", "Delete", new { id = item.ID })
                </td>
            </tr>
        } 
} 
</table>